<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>AI推荐营销分析系统</title>
    
    <!-- CSS - 本地资源 -->
    <link href="/assets/libs/css/bootstrap.min.css" rel="stylesheet">
    <link href="/assets/libs/css/dataTables.bootstrap5.min.css" rel="stylesheet">
    <link href="/assets/libs/css/sweetalert2.min.css" rel="stylesheet">
    <link href="/assets/libs/css/toastr.min.css" rel="stylesheet">
    <link href="/assets/css/custom.css" rel="stylesheet">
    
    <style>
        body {
            font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
        }
        .sidebar {
            position: fixed;
            top: 56px;
            bottom: 0;
            left: 0;
            z-index: 100;
            padding: 48px 0 0;
            box-shadow: inset -1px 0 0 rgba(0, 0, 0, .1);
            background-color: #f8f9fa;
        }
        .sidebar-sticky {
            position: relative;
            top: 0;
            height: calc(100vh - 48px);
            padding-top: .5rem;
            overflow-x: hidden;
            overflow-y: auto;
        }
        .sidebar .nav-link {
            font-weight: 500;
            color: #333;
            padding: 12px 20px;
            transition: all 0.3s;
        }
        .sidebar .nav-link:hover {
            color: #007bff;
            background-color: #e7f3ff;
        }
        .sidebar .nav-link.active {
            color: #007bff;
            background-color: #e7f3ff;
            border-left: 3px solid #007bff;
        }
        #main-content {
            margin-left: 250px;
            padding: 20px;
        }
        .navbar-brand {
            font-size: 1.25rem;
            font-weight: 600;
        }
    </style>
</head>
<body>
    <!-- 顶部导航栏 -->
    <nav class="navbar navbar-dark sticky-top bg-dark flex-md-nowrap p-0 shadow">
        <a class="navbar-brand col-md-3 col-lg-2 me-0 px-3" href="#">
            🤖 AI营销分析系统
        </a>
        <div class="navbar-nav">
            <div class="nav-item text-nowrap">
                <span class="nav-link px-3 text-white">欢迎使用</span>
            </div>
        </div>
    </nav>

    <div class="container-fluid">
        <div class="row">
            <!-- 侧边栏 -->
            <nav id="sidebarMenu" class="col-md-3 col-lg-2 d-md-block sidebar collapse">
                <div class="sidebar-sticky pt-3">
                    <ul class="nav flex-column">
                        <li class="nav-item">
                            <a class="nav-link active" href="#" onclick="loadPage('/pages/analysis/dashboard.html')">
                                📊 数据看板
                            </a>
                        </li>
                        
                        <li class="nav-item mt-3">
                            <h6 class="sidebar-heading px-3 mb-1 text-muted">
                                基础数据管理
                            </h6>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="#" onclick="loadPage('/pages/question/list.html')">
                                📝 问句管理
                            </a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="#" onclick="loadPage('/pages/product/list.html')">
                                📦 产品管理
                            </a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="#" onclick="loadPage('/pages/category/list.html')">
                                📑 产品类别管理
                            </a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="#" onclick="loadPage('/pages/competitor/list.html')">
                                🔍 竞品管理
                            </a>
                        </li>
                        
                        <li class="nav-item mt-3">
                            <h6 class="sidebar-heading px-3 mb-1 text-muted">
                                采集任务
                            </h6>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="#" onclick="loadPage('/pages/task/list.html')">
                                📋 任务管理
                            </a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="#" onclick="loadPage('/pages/task/results.html')">
                                📊 结果查看
                            </a>
                        </li>
                        
                        <li class="nav-item mt-3">
                            <h6 class="sidebar-heading px-3 mb-1 text-muted">
                                数据分析
                            </h6>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="#" onclick="loadPage('/pages/analysis/list.html')">
                                📊 分析任务列表
                            </a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="#" onclick="loadPage('/pages/analysis/competitor.html')">
                                📈 竞品分析
                            </a>
                        </li>
                        
                        <li class="nav-item mt-3">
                            <h6 class="sidebar-heading px-3 mb-1 text-muted">
                                任务管理（待开发）
                            </h6>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link disabled" href="#">
                                ⚙️ 采集任务
                            </a>
                        </li>
                    </ul>
                </div>
            </nav>

            <!-- 主内容区 -->
            <main id="main-content" class="col-md-9 ms-sm-auto col-lg-10 px-md-4">
                <div id="content-area">
                    <!-- 动态加载页面内容 -->
                    <div class="d-flex justify-content-center align-items-center" style="min-height: 400px;">
                        <div class="text-center">
                            <h3>欢迎使用 AI推荐营销分析系统</h3>
                            <p class="text-muted mt-3">请从左侧菜单选择功能</p>
                        </div>
                    </div>
                </div>
            </main>
        </div>
    </div>

    <!-- JS库 - 本地资源 -->
    <script src="/assets/libs/js/jquery.min.js"></script>
    <script src="/assets/libs/js/bootstrap.bundle.min.js"></script>
    <script src="/assets/libs/js/axios.min.js"></script>
    <script src="/assets/libs/js/jquery.dataTables.min.js"></script>
    <script src="/assets/libs/js/dataTables.bootstrap5.min.js"></script>
    <script src="/assets/libs/js/echarts.min.js"></script>
    <script src="/assets/libs/js/dayjs.min.js"></script>
    <script src="/assets/libs/js/sweetalert2.all.min.js"></script>
    <script src="/assets/libs/js/toastr.min.js"></script>
    
    <!-- 自定义JS -->
    <script src="/assets/js/common/config.js?v=20251011-7"></script>
    <script src="/assets/js/common/utils.js?v=20251011-7"></script>
    <script src="/assets/js/common/api.js?v=20251011-7"></script>
    <script src="/assets/js/common/main.js?v=20251011-7"></script>
</body>
</html>
